AppendToFile

Appends text to a file. Creates the file if it does not exist.

For example, use this statement to capture data in a file during playback and import the data into another application to use it for other purposes.

Note: Issues may occur when using this statement in load test scripts.

Syntax

AppendToFile("FilePath", "Text", Encoding)

Arguments

Argument Description
FilePath Full path to the file. See Identifying files and directories in statements for information about configuring full paths relative to the workspace or script directory.
Text Text to append to the file.
Encoding File encoding constant. If not specified, EncodingAutoDetect is used. See Constants.

Example

AppendToFile("C:\\Testing\\Output.txt", "Value added to Product table", EncodingAutoDetect)